package net.xxcxcxcx.xc_enhancedmob.render.particle.summon;

import net.fabricmc.api.EnvType;
import net.fabricmc.api.Environment;
import net.fabricmc.api.EnvironmentInterface;
import net.fabricmc.api.EnvironmentInterfaces;
import net.minecraft.client.world.ClientWorld;
import net.minecraft.network.PacketByteBuf;

@EnvironmentInterfaces(value = {@EnvironmentInterface(value = EnvType.CLIENT, itf = ClientWorld.class)})
public interface CustomSummonParticle {
    //文件从NBT读取
    default void read(PacketByteBuf buf) {

    }

    //文件保存为NBT
    default void write(PacketByteBuf buf) {
    }

    //自动生成CustomID
    default int getID() {
        return 0;
    }

    //每秒中要执行的粒子效果
    @Environment(value = EnvType.CLIENT)
    default void Dotick(ClientWorld clientWorld) {

    }

    //粒子效果还能否执行
    @Environment(value = EnvType.CLIENT)
    default boolean CanUse(ClientWorld clientWorld) {
        return false;
    }

}
